package jogoprojetopi;

import java.awt.Rectangle;
import java.io.IOException;
import java.util.logging.*;
import s3t.gameControl.system.GameSystem;
import s3t.gameElements.Element;
import s3t.graphicsElements.*;

public class Bombas
{

    private Element bomba;
    public long tempoDeVida = 0;
    public long tempoDeCriacao = 0;

    public Bombas(String name, int posicaoX, int posicaoY)
    {

        bomba = new Element(name, posicaoX, posicaoY, LoadIMages.scenario);
        tempoDeCriacao = System.currentTimeMillis();
        LoadIMages.iCollectionBomba.setDefaultKey("BombaTempo1");

        /*****incluindo a bomba na engine*****/

        bomba.setImageCollection(LoadIMages.iCollectionBomba);
        bomba.setCollisionListener( new CollisionDaBomba() );
        GameSystem.getInstance().getAIEngine().setIAElement(bomba, new ControleDaBomba(this));
        GameSystem.getInstance().getElementCollection().addElement(bomba);
    }
}
